Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Terraform support for best path selection #11825

Merged
merged 2 commits into from
Oct 1, 2024

Conversation

akshat-jindal-nit
Copy link
Contributor

@akshat-jindal-nit akshat-jindal-nit commented Sep 26, 2024

Modified the following beta fields in google_compute_network Gateway resource (b/343562168)

  • gateway_ip_version (enum): Added new enum field "bgp_best_path_selection_mode" with possible values Legacy and Standard
  • bgp_bps_always_compare_med (bool): Added new bool field
  • gateway_ip_version (bgp_bps_inter_region_cost): Added new enum field "bgp_bps_inter_region_cost" with possible values Default and Add-cost-to-med

3 new beta output fields for google_compute_router_status for best_routes & best_routes_for_router fields

  • gateway_ip_version (enum): Added new enum field "bgp_best_path_selection_mode" with possible values Legacy and Standard
  • route.next_hop_origin
  • route.next_hop_med
  • route.next_hop_inter_region_cost
    Release Note Template for Downstream PRs (will be copied)
compute: added `bgp_best_path_selection_mode `,`bgp_bps_always_compare_med` and `bgp_bps_inter_region_cost ` fields to `google_compute_network` resource
compute: added `next_hop_origin `,`next_hop_med ` and `next_hop_inter_region_cost ` output fields to `google_compute_route` resource

Copy link

Hello! I am a robot. Tests will require approval from a repository maintainer to run.

@c2thorn, a repository maintainer, has been assigned to review your changes. If you have not received review feedback within 2 business days, please leave a comment on this PR asking them to take a look.

You can help make sure that review is quick by doing a self-review and by running impacted tests locally.

@github-actions github-actions bot requested a review from c2thorn September 26, 2024 05:11
@modular-magician modular-magician added the awaiting-approval Pull requests that need reviewer's approval to run presubmit tests label Sep 26, 2024
Copy link
Contributor

@harshithpatte-g harshithpatte-g left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Added minor comments and suggestions

@c2thorn
Copy link
Member

c2thorn commented Sep 26, 2024

Hi @akshat-jindal-nit,

The Magic Modules repository has recently migrated from Ruby to Go. You can view more details about this in our announcement here: hashicorp/terraform-provider-google#19583 (or go/mm-migration-announcement if you are a Googler)

This open pull request has likely become incompatible due to most YAML and .erb files converting to Go-compatible files.

Our team (Magic Modules repository maintainers) has tooling to automatically convert changes to the new language, and we can prepare a new commit for this pull request that is compatible with the migration.

In order to push the new changes to your pull request, we would need to force push the commit to your fork's branch. Our tooling saves a backup branch before converting, so we could rollback or open a new pull request if needed. We would also work with you and the PR reviewer in the event additional changes are needed.

You also have the option to update the pull request yourself. You can view updated documentation related to the migration changes.

We will take no action until we have your explicit permission to push changes to your fork's branch used for this pull request. Let me know if you have any further questions!

@harshithpatte-g
Copy link
Contributor

harshithpatte-g commented Sep 27, 2024

Hi @akshat-jindal-nit,

The Magic Modules repository has recently migrated from Ruby to Go. You can view more details about this in our announcement here: hashicorp/terraform-provider-google#19583 (or go/mm-migration-announcement if you are a Googler)

This open pull request has likely become incompatible due to most YAML and .erb files converting to Go-compatible files.

Our team (Magic Modules repository maintainers) has tooling to automatically convert changes to the new language, and we can prepare a new commit for this pull request that is compatible with the migration.

In order to push the new changes to your pull request, we would need to force push the commit to your fork's branch. Our tooling saves a backup branch before converting, so we could rollback or open a new pull request if needed. We would also work with you and the PR reviewer in the event additional changes are needed.

You also have the option to update the pull request yourself. You can view updated documentation related to the migration changes.

We will take no action until we have your explicit permission to push changes to your fork's branch used for this pull request. Let me know if you have any further questions!

@c2thorn Could you please run the tool and convert this PR to be compatible with the migrated mmv1 version as a new comment? That would help. Thanks a ton.

@akshat-jindal-nit
Copy link
Contributor Author

@c2thorn Could you please run the tool and convert this PR to be compatible with the migrated mmv1 version as a new comment? That would help. Thanks a ton

@c2thorn Could you please run the tool and convert this PR to be compatible with the migrated mmv1 version as a new commit? thanks

use default function
update example and used default field testcheckResourceAttr
add beta version tag
Add bgp best path slection support to network
Copy link

@c2thorn This PR has been waiting for review for 3 weekdays. Please take a look! Use the label disable-review-reminders to disable these notifications.

@modular-magician modular-magician added service/compute-vpc and removed awaiting-approval Pull requests that need reviewer's approval to run presubmit tests labels Sep 30, 2024
@modular-magician
Copy link
Collaborator

Hi there, I'm the Modular magician. I've detected the following information about your changes:

Diff report

Your PR generated some diffs in downstreams - here they are.

google provider: Diff ( 2 files changed, 61 insertions(+))
google-beta provider: Diff ( 6 files changed, 528 insertions(+), 1 deletion(-))
terraform-google-conversion: Diff ( 1 file changed, 33 insertions(+))

@modular-magician
Copy link
Collaborator

Tests analytics

Total tests: 1025
Passed tests: 943
Skipped tests: 74
Affected tests: 8

Click here to see the affected service packages
  • compute

Action taken

Found 8 affected test(s) by replaying old test recordings. Starting RECORDING based on the most recent commit. Click here to see the affected tests
  • TestAccComputeNetwork_bgpAlwaysCompareMedAndUpdate
  • TestAccComputeNetwork_bgpBestPathSelectionModeAndUpdate
  • TestAccComputeNetwork_bgpInterRegionCostAndUpdate
  • TestAccComputeNetwork_default_bgp_always_compare_med
  • TestAccComputeNetwork_default_bgp_best_path_selection_mode
  • TestAccComputeNetwork_networkBgpBestPathSelectionModeExample
  • TestAccComputeNetwork_networkBgpBestPathSelectionModeStandardCustomFieldsExample
  • TestAccComputeNetwork_networkBgpBestPathSelectionModeStandardExample

Get to know how VCR tests work

@modular-magician
Copy link
Collaborator

$\textcolor{green}{\textsf{Tests passed during RECORDING mode:}}$
TestAccComputeNetwork_bgpAlwaysCompareMedAndUpdate[Debug log]
TestAccComputeNetwork_bgpInterRegionCostAndUpdate[Debug log]
TestAccComputeNetwork_default_bgp_always_compare_med[Debug log]

$\textcolor{green}{\textsf{No issues found for passed tests after REPLAYING rerun.}}$


$\textcolor{red}{\textsf{Tests failed during RECORDING mode:}}$
TestAccComputeNetwork_bgpBestPathSelectionModeAndUpdate[Error message] [Debug log]
TestAccComputeNetwork_default_bgp_best_path_selection_mode[Error message] [Debug log]
TestAccComputeNetwork_networkBgpBestPathSelectionModeExample[Error message] [Debug log]
TestAccComputeNetwork_networkBgpBestPathSelectionModeStandardCustomFieldsExample[Error message] [Debug log]
TestAccComputeNetwork_networkBgpBestPathSelectionModeStandardExample[Error message] [Debug log]

$\textcolor{red}{\textsf{Errors occurred during RECORDING mode. Please fix them to complete your PR.}}$

View the build log or the debug log for each test

@c2thorn
Copy link
Member

c2thorn commented Sep 30, 2024

resource_compute_network_test.go:120: Step 1/2 error: Check failed: Check 2/2 error: google_compute_network.acc_network_bgp_best_path_selection_mode: Attribute 'RoutingConfig.BgpBestPathSelectionMode' not found

@modular-magician modular-magician added awaiting-approval Pull requests that need reviewer's approval to run presubmit tests and removed awaiting-approval Pull requests that need reviewer's approval to run presubmit tests labels Oct 1, 2024
@modular-magician
Copy link
Collaborator

Hi there, I'm the Modular magician. I've detected the following information about your changes:

Diff report

Your PR generated some diffs in downstreams - here they are.

google provider: Diff ( 2 files changed, 64 insertions(+))
google-beta provider: Diff ( 6 files changed, 574 insertions(+), 1 deletion(-))
terraform-google-conversion: Diff ( 1 file changed, 33 insertions(+))

@modular-magician
Copy link
Collaborator

Tests analytics

Total tests: 1026
Passed tests: 947
Skipped tests: 74
Affected tests: 5

Click here to see the affected service packages
  • compute

Action taken

Found 5 affected test(s) by replaying old test recordings. Starting RECORDING based on the most recent commit. Click here to see the affected tests
  • TestAccComputeNetwork_bgpBestPathSelectionModeAndUpdate
  • TestAccComputeNetwork_default_bgp_best_path_selection_mode
  • TestAccComputeNetwork_networkBgpBestPathSelectionModeExample
  • TestAccComputeNetwork_networkBgpBestPathSelectionModeStandardCustomFieldsExample
  • TestAccComputeNetwork_networkBgpBestPathSelectionModeStandardExample

Get to know how VCR tests work

@modular-magician
Copy link
Collaborator

🟢 Tests passed during RECORDING mode:
TestAccComputeNetwork_bgpBestPathSelectionModeAndUpdate[Debug log]
TestAccComputeNetwork_default_bgp_best_path_selection_mode[Debug log]
TestAccComputeNetwork_networkBgpBestPathSelectionModeExample[Debug log]
TestAccComputeNetwork_networkBgpBestPathSelectionModeStandardCustomFieldsExample[Debug log]
TestAccComputeNetwork_networkBgpBestPathSelectionModeStandardExample[Debug log]

🟢 No issues found for passed tests after REPLAYING rerun.


🟢 All tests passed!

View the build log or the debug log for each test

@c2thorn c2thorn merged commit 3be900f into GoogleCloudPlatform:main Oct 1, 2024
14 checks passed
karolgorc pushed a commit to karolgorc/magic-modules that referenced this pull request Oct 4, 2024
niharika-98 pushed a commit to niharika-98/magic-modules that referenced this pull request Oct 7, 2024
trodge pushed a commit to trodge/magic-modules that referenced this pull request Oct 10, 2024
karolgorc pushed a commit to karolgorc/magic-modules that referenced this pull request Oct 11, 2024
gontech pushed a commit to gontech/magic-modules that referenced this pull request Oct 16, 2024
BBBmau pushed a commit to BBBmau/magic-modules that referenced this pull request Oct 23, 2024
BBBmau pushed a commit to BBBmau/magic-modules that referenced this pull request Oct 24, 2024
BBBmau pushed a commit to BBBmau/magic-modules that referenced this pull request Nov 5, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants